special-protocols: Device Toggler
---------------------------------

This protocol allows you to assign two Setup Codes on one 
Device button, and toggle between them with the press of a 
button of your choosing.

For example, if you have an Amplifier/Tuner, you could use 
the SURR key to make the number keys control either the 
active input, or the radio station.

Since the assigned button acts as a toggle, it isn't 
suitable for macros. If you need to change device codes from 
inside macros, use the Device-Multiplexor protocol instead.

To use the Device Toggler protocol, follow these steps:

1) In the Other Data fields, enter Device 1, Setup Cd 1, 
Device 2, and Setup Code 2 to compute the required Hex Cmd.
2) Copy & paste the Device Upgrade code into the IR 
[Devices] tab.
3) Copy & paste the Protocol Upgrade code into the IR 
[Protocols] tab.
4) Assign one of the Setup Codes to a device button on the 
IR [General] tab.
5) Create a Key Move for the button you want to use to 
toggle between the two Setup Codes by entering the 
following:

   Device: The Device Button that the first Setup Code was 
assigned to in step 4.
   Key: The button you want to use to toggle between the two 
Setup Codes.
   Device Type: The Device selected in the Device Type box.
   Setup Code: The Setup Code entered in the Setup Code box.
   EFC/Hex Cmd: The Hex Cmd from the Other Data Hex Cmd 
column (be sure to click the Hex Cmd radio button in IR).

Now, whenever you press the selected button key while in 
selected device mode, you will toggle between the two Setup 
Codes.

The Setup Code change is remembered even when you switch
away from the device, so you can press other device buttons,
then press the device button again, and the setup code
toggle will still be in the state you last toggled it to.

Note: Key Moves always have precedence over the default keys
for a device and a Key Move retains the setup code it was
defined with, even when the bound device's setup code changes.
This means that keys defined by Key Move are shared by the two
virtual devices created by the device toggler.
